<template>
  <!--换绑紧急联系人-->
  <div>
    <wv-group>
      <wv-input label="紧急手机号：" type="text" v-model="telephone" class="readonly"/>
    </wv-group>
    <p class="offer" @click="goNext(telephone)">确定</p>
  </div>
</template>

<script type="text/ecmascript-6">
  import {changeTelePhone} from '../../../../test/unit/http'
  import {Toast} from 'we-vue'
  export default {
    name: 'changeemergency',
    props: {},
    data() {
      return {
        telephone: ''
      };
    },
    methods: {
      goNext(telephone){
        changeTelePhone({telephone: telephone}).then(res => {
          console.log(res);
          if (res.code == 100) {
            Toast.text('换绑成功');
            this.$router.go(-1);
          }
        })
      }
    } ,
    created(){

    }
    ,
    components: {}
  }
</script>


<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped lang="less">
  input::-webkit-input-placeholder {
    color: #999;
  }

  .weui-vcode-btn {
    color: #2f95f0;
    border: 1px solid #2f95f0;
    width: 110px;
  }

  .count {
    color: #fff;

  }

  .tip {
    color: #e96674;
    font-size: 13px;
    margin: 15px;
  }

  .offer {
    position: fixed;
    bottom: 0;
    width: 100%;
    background-image: linear-gradient(to left, #4c92ed, #61beec);
    height: 50px;
    line-height: 50px;
    color: #fff;
  }
</style>
